<%-- 
    Document   : index5
    Created on : 2015-9-24, 11:47:45
    Author     : Fire
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
        <script src="plugins/react/react.js" type="text/javascript"></script>
        <script src="plugins/react/browser.min.js" type="text/javascript"></script>
    </head>
    <body>
        <script type="text/babel">
            var nodelist = React.createClass({
                render:function(){
                    return (
                        <ol>
                            {
                                this.props.children.map(
                                   function(child){
                                     return <li>{child}< /li>
                                    })
                            }
                        </ol> 
                    );
                }
            });
            React.render(
                <nodelist>
                    <span>hello</span>
                    <span>world</span>
                    </nodelist>,
                document.body
            );
        </script>
    </body>
</html>
